package com.cqemme.activitiservice.service;

import org.activiti.engine.delegate.DelegateExecution;

import java.util.Map;

/**
 * @author nejery
 */
public interface ListenerService {

    /**
     * 发送到学校保存
     * @param execution execution
     */
    void sendToSchoolSave(DelegateExecution execution);


    /**
     * 发送每一个节点的消息,
     * @param execution execution
     */
    void sendNodeMessage(DelegateExecution execution);


    /**
     * 设置流程变量值
     * @param execution execution
     * @param key key
     * @param value value
     */
    void  setVariable(DelegateExecution execution,String key ,String value);


    /**
     * 获取当前节点的模型变量
     *@param execution execution
     * @return virables 变量集合
     */
    Map getCurrentNodeBpmnVariables(DelegateExecution execution);



    /**
     * 获取变量中最近一个后缀变量值
     * @param execution execution
     * @param endFix 后缀
     * @return 结果值
     */
     String getLastNodeValue(DelegateExecution execution, String  endFix);

    /**
     * 设置重复次数变量
     * @param execution 执行对象
     */
    void repeatSendMessage(DelegateExecution execution);
}
